package controller;

import java.io.File;

/**
 * Interface that provide the operation needed to control the application.
 * 
 * @author GRONOWSKI Stephane svan001@aol.com
 * 
 *         igsat 2010
 * 
 */
public interface IController {

	/**
	 * Change the default directory where the solver executable file are suppose to be.
	 * 
	 * @param directory
	 *            the new directory.
	 * @return if the directory was change.
	 */
	public boolean changeSolverDirectory(File directory);

	/**
	 * Change the default directory where the preprocessor executable file are suppose to be.
	 * 
	 * @param directory
	 *            the new directory.
	 * @return if the directory was change.
	 */
	public boolean changePreProcessorDirectory(File directory);

	/**
	 * Change the default directory where the new CNF will be stored.
	 * 
	 * @param directory
	 *            the new directory.
	 * @return if the directory was change.
	 */
	public boolean changeDefaultCNFDirectory(File directory);

	/**
	 * Return the default directory where the solver executable file are suppose to be.
	 * 
	 * @return the default directory where the solver executable file are suppose to be.
	 */
	public File getSolverDirectory();

	/**
	 * Return the default directory where the preprocessor executable file are suppose to be.
	 * 
	 * @return the default directory where the preprocessor executable file are suppose to be.
	 */
	public File getPreProcessorDirectory();

	/**
	 * Return the default directory where the new CNF will be stored.
	 * 
	 * @return the default directory where the new CNF will be stored.
	 */
	public File getDefaultCNFDirectory();

	// cnf
	/**
	 * Ask to open a new Session.
	 * 
	 * @param cnf
	 *            path of the cnf file
	 */
	public void openSession(String cnf);

	/**
	 * Ask for open a new cnf.
	 * 
	 * @param cnf
	 *            the file cnf
	 */
	public void openSession(File cnf);

	/**
	 * End the treatment of the cnf.
	 * 
	 * @param cnf
	 *            the cnfuse concern
	 */
	public void closeSession(ISessionManager cnf);

	/**
	 * Close the all application.
	 */
	void close();

}
